#Opcode Caching for WordPress
Explore tagged Tumblr posts
jnexttech · 10 months ago
Text
Advanced WordPress Caching
Tumblr media
Speed is important in the fast-paced world of online presence. Users expect websites to load in the blink of an eye, and search engines reward faster sites with better rankings. If you’re a WordPress enthusiast, you probably already know how crucial caching is to maximising the functionality of your website. We’ll explore sophisticated WordPress caching strategies in this blog post, which can significantly increase the speed of your website.
0 notes
isabellaseraphinabloger · 7 months ago
Text
Unveiling the Popularity of PHP in Web Development
Tumblr media
In the realm of web development, PHP stands tall as one of the most prevalent and sought-after programming languages. PHP Is So Famous For Web Development that its presence permeates countless websites, from simple blogs to complex e-commerce platforms. But what exactly makes PHP so popular in this digital landscape?
Flexibility and Versatility: PHP's versatility is unmatched. Whether you're building a small personal website or a large-scale enterprise application, PHP provides the tools and features necessary to get the job done efficiently. Its flexibility allows developers to tailor solutions to meet specific needs, making it an ideal choice for a wide range of projects.
Open Source Nature: PHP's open-source nature has been a driving force behind its widespread adoption. As an open-source language, PHP is constantly evolving with contributions from a vast community of developers worldwide. This means frequent updates, bug fixes, and improvements, ensuring that PHP remains relevant and competitive in the ever-changing landscape of web development.
Ease of Learning and Deployment: One of the key reasons for PHP's popularity is its ease of learning. With a syntax that resembles natural language, beginners find it relatively easy to grasp the basics of PHP programming. Additionally, PHP integrates seamlessly with various web servers, making deployment a breeze. This accessibility lowers the entry barrier for aspiring developers, further fueling PHP's popularity.
Vast Ecosystem of Tools and Frameworks: PHP boasts a rich ecosystem of tools, frameworks, and libraries that expedite development processes. From popular frameworks like Laravel and Symfony to content management systems like WordPress and Drupal, developers have access to a plethora of resources that streamline development and enhance productivity.
Scalability and Performance: Despite its humble beginnings, PHP has evolved into a robust and scalable language capable of powering high-traffic websites and applications. With advancements in performance optimization techniques and the introduction of features like opcode caching, PHP can handle demanding workloads with ease, making it a reliable choice for projects of any scale.
In conclusion, the popularity of PHP in web development can be attributed to its flexibility, open-source nature, ease of learning, vast ecosystem, and scalability. As technology continues to evolve, PHP remains a cornerstone of the web development landscape, continuing to empower developers to create innovative and dynamic web experiences.
0 notes
bigcloudy-hosting-blog · 11 months ago
Text
How Can You Improve WordPress Site’s Performance?
Tumblr media
In today’s digital age, where attention spans are shorter than ever, WordPress website speed and performance play a crucial role in the success of any online business.
In this article, furthermore, we will explore how BigCloudy can help you achieve a 30X faster performance for your WordPress site, ensuring your website stands out in the digital landscape.
How BigCloudy can help achieve 30X faster performance for your WordPress site
BigCloudy is a powerful cloud-based platform that specializes in optimizing website speed and performance. With its advanced caching techniques and content delivery network (CDN), BigCloudy can significantly enhance the loading speed of your WordPress site. By caching static content and distributing it across multiple servers worldwide, BigCloudy reduces the distance between your website and its users, resulting in faster page load times.
1. High-performance Infrastructure for WordPress site
BigCloudy provides a robust infrastructure that is optimized for speed. They utilize powerful servers with fast CPUs, ample memory, and SSD storage to ensure rapid processing and data retrieval, resulting in improved overall performance.
2. Your website’s Static Content Delivery Network (CDN) Integration
BigCloudy seamlessly integrates with a global CDN, which helps deliver your website’s static content (such as images, CSS, and JavaScript files) from servers located strategically around the world. By caching and serving these files from the nearest CDN server to the user’s location, BigCloudy minimizes latency and reduces loading times, resulting in faster page loads.
3. Server-level Caching
BigCloudy implements server-level caching mechanisms to accelerate WordPress site performance. They employ advanced caching techniques, such as opcode caching, object caching, and page caching.
4. Advanced Caching Plugins
BigCloudy supports and recommends the use of popular caching plugins specific to WordPress, such as W3 Total Cache or WP Rocket. These plugins further enhance caching capabilities, allowing you to leverage additional caching features and fine-tune caching settings to achieve optimal performance.
5. Optimized Database Performance
BigCloudy optimizes database performance to enhance your WordPress site’s speed. They utilize techniques like database query caching, which caches frequently executed queries, reducing the overhead of querying the database.
6. Automated Image Optimization
Images can significantly impact page load times. BigCloudy offers automated image optimization features that compress and optimize images without sacrificing quality. By reducing image file sizes, your WordPress site can load faster and provide a better user experience.
7. Minification of CSS and JavaScript
BigCloudy automatically minifies and combines CSS and JavaScript files on your WordPress site. Minification removes unnecessary characters, whitespace, and comments from these files, reducing their size. By minimizing file sizes, BigCloudy helps improve the loading speed of your site.
8. Advanced Caching Plugins
BigCloudy supports and recommends the use of popular caching plugins specific to WordPress, such as W3 Total Cache or WP Rocket. These plugins further enhance caching capabilities, allowing you to leverage additional caching features and fine-tune caching settings to achieve optimal performance.
 9. Expert Support and Guidance
BigCloudy provides expert support and guidance to optimize your WordPress site for speed. Their support team can assist you with configuring caching settings, optimizing plugins, and implementing best practices to maximize your site’s performance.
Tumblr media
Measuring the performance improvements and benefits of using BigCloudy
To evaluate the performance improvements achieved through BigCloudy, it is essential to have reliable metrics in place.
By monitoring key performance indicators (KPIs) such as page load time, time to first byte (TTFB), and the number of requests made to the server, you can accurately measure the impact of BigCloudy on your WordPress site.
One of the significant benefits of using BigCloudy is the significant reduction in page load time. With its caching and optimization techniques, BigCloudy can reduce the time it takes for your website to load, resulting in a better user experience.
Moreover, faster load times also contribute to improved search engine rankings, as search engines prioritize fast-loading websites.
Another benefit of using BigCloudy is the scalability it offers.
As your website grows and attracts more visitors, BigCloudy automatically scales its infrastructure to handle the increased traffic, ensuring your website’s performance remains consistent. This scalability eliminates the need for manual server upgrades or additional infrastructure investments, saving you time and resources.
Conclusion
In today’s competitive online landscape, achieving the lightning-fast performance of your WordPress site is crucial for success. BigCloudy provides a comprehensive solution to optimize your website’s speed and performance, offering caching, content delivery network, and various optimization features.
0 notes
Text
The Complete Guide to PHP Web Development Services - Connect Infosoft
When it comes to server-side scripting, no language is more popular than PHP. Despite the fact that some developers prefer Python or Java, PHP's popularity continues to grow. PHP, a branch of C, is one of the oldest programming languages available, focusing mostly on the online development environment. PHP apps can be found all over the place.
WordPress, a popular web hosting and development engine, is built on PHP. Given the widespread use of the PHP programming language, it is worthwhile to employ PHP development services. There are numerous benefits to adopting the PHP programming language for web development. It is inexpensive and straightforward to set up, making the application simple to deploy. Let us look at some fundamental aspects of the PHP programming language that you should be familiar with.
Tumblr media
What is Php?
PHP (Hypertext Preprocessor) is a popular web development server-side programming language. It is an open-source language that is embedded within HTML code and executed on the server to generate dynamic web content. PHP is known for its simplicity and flexibility, making it popular among developers for creating dynamic websites and web applications. PHP web development services refer to the range of services provided by web development companies or professionals using PHP as the primary programming language.
PHP's primary purpose is web development, but it can also be used for command-line scripting and other general-purpose programming tasks. It is widely adopted worldwide and powers numerous websites, including social media platforms, content management systems, e-commerce websites, and more.
Key Features Of PHP Include:
Server-Side Scripting:
PHP is executed on the server, generating HTML output that is then sent to the client's web browser. This enables dynamic content generation and interaction with databases, files and other server resources.
Easy Integration:
PHP can be seamlessly integrated with HTML, allowing developers to embed PHP code directly within HTML code. This makes it easy to mix server-side and client-side logic.
Cross-Platform Compatibility:
PHP is available for various operating systems, including Windows, macOS, Linux, and Unix. It can run on popular web servers like Apache, Nginx, and Microsoft IIS.
Wide Database Support:
PHP has built-in support for many databases, including MySQL, PostgreSQL, Oracle, SQLite, and more. It provides functions and extensions to interact with databases, allowing data storage, retrieval and manipulation.
Powerful Functionality:
PHP offers a wide range of built-in functions and features for various tasks such as file handling, form validation, session management, encryption, image processing and more. It also supports object-oriented programming (OOP) principles.
Scalability and Performance:
PHP can handle high traffic and large-scale applications effectively. When combined with caching mechanisms, opcode caching, and performance optimization techniques, PHP can deliver efficient and fast web applications.
Here's A Complete Guide To PHP Web Development Services:
Custom Web Application Development:
PHP is used to build custom web applications tailored to specific business needs. PHP web development services involve analyzing requirements, designing the application architecture, writing clean and efficient PHP code, and implementing features and functionality.
Content Management Systems (CMS) Development:
PHP is the backbone of popular CMS platforms such as WordPress, Drupal, and Joomla. PHP web development services include CMS customization, theme development, plugin/module creation, and integration to build dynamic and content-rich websites or blogs.
E-Commerce Solutions:
PHP is widely utilized for developing e-commerce websites and online stores. PHP web development services involve creating custom e-commerce solutions or leveraging PHP-based frameworks like Magento, WooCommerce, or PrestaShop. This includes features such as product catalogs, shopping carts, payment gateway integration, order management, and secure transaction processing.
Database Integration:
PHP web development services include integration with databases to store and retrieve data. PHP supports various databases like MySQL, PostgreSQL, Oracle, and MongoDB. PHP developers use database functions or ORMs (Object-Relational Mapping) like Doctrine to interact with databases, perform data manipulation, and ensure data persistence.
API Development and Integration:
PHP is used for building RESTful APIs (Application Programming Interfaces) that facilitate communication and data exchange between different systems or platforms. PHP web development services involve designing, developing, and securing APIs, as well as integrating third-party APIs for enhanced functionality and integrations with other systems.
Maintenance and Support:
PHP web development services encompass ongoing maintenance and support to ensure the smooth operation of websites or web applications. This includes bug fixing, security updates, performance optimization, server management, and regular backups.
Website Migration and Upgrades:
PHP web development services may involve migrating existing websites or applications to PHP or upgrading them to newer PHP versions. This ensures better performance, enhanced security, and access to new features and functionalities.
Responsive Web Design:
PHP web development services focus on creating responsive web designs that adapt to different screen sizes and devices. This involves implementing responsive layouts, optimizing images and media, and ensuring a consistent user experience across desktops, tablets, and mobile devices.
Integration with Other Technologies:
PHP web development services often involve integrating PHP applications with other technologies such as JavaScript frameworks (e.g., React, Vue.js), payment gateways, social media APIs, third-party services and more. These integrations enhance website functionality, user experience and interoperability with other systems.
Quality Assurance and Testing:
PHP web development services include thorough testing to ensure the quality, reliability and security of the developed applications. This involves unit testing, integration testing, performance testing and security testing.
Conclusion:
When seeking PHP web development services, it's important to choose a reputable and experienced development team or company. Consider their expertise in PHP, knowledge of relevant frameworks and technologies, portfolio of past projects, customer reviews and their ability to understand and fulfill your specific requirements. Effective communication, adherence to best practices, and a collaborative approach are also crucial for successful PHP web development projects.
TAGS: Guide to PHP Web Development Services, Hire PHP8 Developers, Connect Infosoft Technologies, Hire PHP8 Development Solution, Looking for PHP8 Development Service, Hire PHP8 Customization Services, Looking for PHP Development Company, Looking Ecommerce Solution, Looking Ecommerce Developers, Ecommerce Dev Team, Hire Ecommerce Solution Developers, Connect Infosoft Technologies, India, USA
1 note · View note
innovtouchsolutions · 1 year ago
Text
How to design faster website?
How to design faster website?
Designing a faster website is crucial for improving user experience, SEO rankings, and overall performance. Here are several tips and best practices to help you create a faster website:
Optimize Images and Media:
Use image compression tools to reduce the file size of images while maintaining quality.
Use responsive images and the element to serve different image sizes based on the user's device and screen size.
Lazy loading: Load images only when they come into the user's viewport.
Minimize HTTP Requests:
Combine CSS and JavaScript files to reduce the number of HTTP requests.
Minify and concatenate CSS and JavaScript files to reduce their size.
Utilize browser caching for static assets to reduce the need for repeated downloads.
Content Delivery Network (CDN):
Use a CDN to distribute your website's content across multiple servers geographically closer to your users. This reduces latency and speeds up loading times.
Optimize Code:
Ensure your code is clean and well-structured.
Remove unused CSS and JavaScript code.
Reduce the use of external scripts and plugins that add unnecessary overhead.
Use Browser Caching:
Set appropriate caching headers for static assets (images, CSS, JavaScript) to instruct the browser to store these resources locally, reducing server requests on subsequent visits.
Reduce Server Response Time:
Choose a reliable and fast web hosting provider.
Use server-side caching mechanisms (e.g., opcode caching, object caching, and page caching).
Optimize your server-side code and database queries.
Optimize Fonts:
Minimize the number of fonts and font variations used on your site.
Consider using system fonts or icon fonts for faster loading.
Asynchronous Loading:
Load non-essential scripts asynchronously to prevent blocking page rendering.
GZIP Compression:
Enable GZIP compression on your web server to reduce the size of transmitted data.
Responsive Design:
Ensure your website is responsive and mobile-friendly to optimize performance on all devices.
Reduce Redirects:
Minimize the use of unnecessary redirects as they add latency to page loading.
Optimize Third-party Resources:
Limit the use of third-party widgets and scripts. If necessary, load them asynchronously.
Image Formats:
Choose the appropriate image format (JPEG, PNG, WebP) for your images. WebP typically offers better compression.
Content Delivery Optimization:
Use a Content Delivery Network (CDN) to serve static content from servers closer to the user's location.
Prioritize Above-the-Fold Content:
Load critical resources (CSS, JavaScript) for above-the-fold content first to ensure a faster initial render.
Monitor and Test:
Regularly monitor your website's performance using tools like Google PageSpeed Insights, GTmetrix, or Pingdom.
Conduct performance testing and optimize accordingly.
Use a Content Management System (CMS) Wisely:
If using a CMS like WordPress, choose lightweight themes and plugins. Remove any unnecessary plugins.
Implement HTTP/2 or HTTP/3:
If your server supports it, consider upgrading to HTTP/2 or HTTP/3 for faster loading of assets.
Optimize for Mobile:
Mobile users often have slower connections. Ensure your site is optimized for mobile performance.
Regularly Update and Maintain:
Keep your website's software, plugins, and themes up to date to benefit from performance improvements and security updates.
Looking for a responsive and faster website? We're a leading website designing company in Chennai, Porur, Adyar specializing in creating high-performance websites for your business needs. Get in touch for a blazing fast, mobile-friendly web presence.
0 notes
kathleenignacio · 5 years ago
Text
Keep your WordPress fit
Tumblr media
The WordPress application has matured a lot in its last ten years of existence . The rationalization of many processes such as updates, such as the standardization of many aspects of its functionality, are a dedication to make it simpler to use and incorporate new functions.
No matter how many automations developed in WordPress management, you still need to take extra measures to ensure that your website is fit in terms of performance and security . In this article I will raise certain questions and suggest certain improvements that will help you sustain your website in good shape.
1. Do you have the WordPress core, plugins and updated themes? update wordpress
I'm sure you've heard about this many times before, but it's still the number one question about the security and performance of a WordPress site.
When I look at the statistics of all our servers in SiteGround, I am always surprised and in all circumstances the amount of people who maintain the previous versions despite each and every one of the comforts that both WordPress and the host offer them to keep up to date. without care. These are certain things you could take advantage of:
1.1 Native Updates You probably remember that as of version 3.7, WordPress introduced a native automatic update feature among the smaller versions. This is a huge feature that can be taken advantage of immediately, and that will keep your web page safe at all times.
Most minor version updates are full of security patches, so you should not skip them under any circumstances. And if your WordPress is not yet version three.7 or higher, update as soon as possible so you can benefit from the native changes.
1.2 Managed Hosting Service Also, certain web hosting companies, SiteGround is one of them, they offer a managed WordPress service where you receive a WordPress auto-update whenever there is a new version , and this also includes updates to major versions. And even some of the hosts offer automatic plugin update when the kernel is self-updated.
1.3 Check the WordPress desktop alarms Finally, if you are not benefiting from the services of your host, on the WordPress desktop you will generally receive alarms about new versions of some active complement or the kernel. You just have to click and update it.
1.4 Add a configuration line to have the kernel updated to important versions If you want your WordPress to automatically update to the important versions, not only the minor ones, you can put the following line in your wp-config.php file :
define( 'WP_AUTO_UPDATE_CORE', true ); 1.5 Check before updating Of course you may have certain fears, completely justified, to deconfigure your website when updating it. In this case, I recommend that you make a copy of your website and try it on it first. Again, you can search for hosts that offer a test environment to make this process uncomplicated .
2. What version of PHP do you have? php 7 wordpress
Does your WordPress still work with PHP 5.2? Was this version the default one million years ago when you installed it?
WordPress has already stopped supporting PHP version five.2 and, normally, they tend to encourage their users to stay in the latest version of PHP. For what reason? Well, new versions of PHP are going better and are safer .
PHP 7 , incorporating the Opcode caching and the expected super-performance, will be launched very, very soon (launch options are free on SiteGround servers and you can easily move).
It is the biggest change in PHP code since PHP4 . The latest version of WordPress already supports it. It is a good idea to test how PHP7 is going on your website and update extensions that do not support it, or try to locate solutions. Do not leave.
comparative speed php 7 wordpress
Updating PHP is not as simple as updating WordPress, however, it is not a reason to neglect it. You can consult your host if you can change the version for yourself, or if you are too afraid to spoil your website, go through the testing process suggested above.
3. Do you have any add-on or theme disabled? hacking WordPress plugins themes
I would like to draw your attention to this as I have seen too many websites with more than 40 add-ons disabled . Keep in mind that although they are disabled, the files with the code are really there, in your account. This could potentially create security problems. The same applies to the topics.
The bottom line is that if you are not using a plugin, remove it completely from your application. If you have some payment plugins and do not want to remove them, make a local copy of each and every one of the payment plugins that you have purchased more than you are not using now.
If you are not using a theme, remove it completely from your application. I would advise leaving the last available WordPress theme by default as a foldback, plus everything else, to get rid of it.
4. When did you last optimize your database and review your old articles? optimize wordpress database
The first thing is to clean your database of all the information you don't need. For an example, WordPress saves multiple revisions of your posts. That is excellent, but it fills you with multiple copies of your blog posts, and also implies a considerable increase in the size of the database.
These revisions will not slow down your website, but they will slow down certain processes such as database optimization, creation of backups, and possible backup copies recovery.
I would like to advise you the Better Delete Revision ”add-on to eliminate them. It lets you remove each and every one of the reviews optimizing your database.
On the optimization itself of the databases, you can use a tool like phpMyAdmin or if you have the WP-CLI at your disposal,
5. Have you optimized the size of your images? compress image
The images are a huge part of your website and it is a great idea to do everything you can to optimize them. I personally divide the process into 2 parts:
5.1 Lower the number of thumbnails When you upload an image to your website, WordPress automatically creates several copies of the image and rescale it. The number of thumbnails created depends on the theme.
Currently, there are many themes that give many layers of different pages, and produce dozens of miniatures of different sizes. This inflates the number of images in your account and their size. My advice is to examine all the page models, write down the thumbnails you are really using, and eliminate the ones you don't use, optimizing the space occupied by the images, and the total number of inodes in your account.
Doing this is partially simple: first open the functions.php file  on your website, and look for a part of thumbnail creation. It should be something like this:
add_image_size( 'thumbnail-name', 255, ciento noventa y uno, true ); Comment only on the lines responsible for the sizes you don't need. Once that is done, you need to regenerate the thumbnails. I invite you to use the Regenerate thumbnails plugin. Keep in mind that it can take hours to regenerate each and every one, so make sure you do not miss any, and also try not to do so during the busiest hours of your website in terms of traffic.
5.2 Optimize existing images The smaller the image size, the faster the page load will be!
Another preferred add-on that I now add on my sites and on all the ones I work on, is EWWW Image Optimizer. Optima without loss of quality each and every one of the images that you upload to your website, and it has a huge button Optimize all ”to do it directly.
Basically, the plugin reduces the size of your images without decreasing their quality. Great results guaranteed!
6. How fast is your website? What loading speed do you have? web speed
In general, the speed of your website suggests what performance optimizations you can start. If your pages take longer to load more than a second and your score on certain speed tests that I lie in this section is low, start with the preceding suggestions to improve it.
Here are certain tools that I use on a regular basis to test the loading speed of the websites I work with:
Each WordPress installation has a different set of themes, plugins and content, and there is no universal solution or a single approach. You need to regularly update your website, test it, and solve the
1 note · View note
danhgiahost · 3 years ago
Text
Servertut Script bài 2: Giới thiệu các công cụ mà Servertut Script cung cấp để quản lý VPS/Server
Servertut Script bài 2: Giới thiệu các công cụ mà Servertut Script cung cấp để quản lý VPS/Server
Sau khi cài đặt hoàn t��t Servertut Script lên VPS/Server, bạn có thể tiến hành quản lý thông qua các công cụ mà script hỗ trợ: 1. Quản lý qua menu chính của script: Với menu chính của script, bạn có thể thực hiện các thao tác thêm, xóa website, sao lưu, tạo/xóa cơ sở dữ liệu, bật/tắt các tính năng APC Opcode Cache, PageSpeed, BTSynch… . Để gọi menu chính của script, chạy…
Tumblr media
View On WordPress
0 notes
i-lathiya-solutions · 4 years ago
Link
Our professional team provides three separate page speed optimization service plans which will help with your website load at top speeds. A number of the consequences you’ll see after implementing our services, include decreased bounce rate and extended time-on-page.
Why is improving your site speed essential?
More Page Views
Better SEO Rankings
Good Brand Representation
Enhanced User Experience
Reduced Bounce Rates
More Conversions
Our WordPress page speed optimization services improve your website’s speed performance, in order that your visitors get an optimized speed experience. 
We do understand that it's your website where potential leads are often converted into while customers, therefore, we make sure that your site loads quickly, thereby having low bounce rates.
We lathiya solutions make sure that you do not face any disadvantages thanks to your slow website.
What We Offer:
Leverage browser caching
Enable compression
Put CSS in the document head
Replace the use of CSS @import
Defer the parsing of and/or asynchronously load JavaScript
Eliminate render-blocking JavaScript and CSS in above-the-fold content
Minify CSS
Minify HTML
Minify JavaScript
Prioritize visible content
Reduce server response time
Optimize images
Implement Full Page Caching
Implement Memory Caching
Implement Fragment Caching
Implement Object Caching
Implement OpCode Caching
Remove query strings from static resources
Specify a cache validator
Specify a character set early
Specify image dimensions
Make sure bad requests are avoided
Minimize request size
Optimize the order of styles and scripts
For More Inquiry:
📞 +91-7878535701
0 notes
sourabhdubey007 · 4 years ago
Text
How to use W3 Total Cache Settings Explained – A Beginner’s Guide
W3 Total Cache Settings Explained – A Beginner’s Guide
Adding a caching plugin to your website is one of the first things to do if you want to speed up your website. Among the best plugins for the job is W3 Total Cache. While the plugin is highly popular with WordPress users, getting through the settings (15+ options in General Settings alone) can scare a beginner. But once you get it right, it can give a boost to site speed. In this post, we’re going to specifically focus on the best W3 Total Cache settings to use on shared WordPress hosting.There’s a lot of ground to cover, so let’s get started.How to configure W3 Total Cache by @w3edge to speed up your #WordPress siteCLICK TO TWEET 
W3 Total cache settings – dashboard
W3 Total Cache
Author(s): BoldGrid
Current Version: 0.14.4
Last Updated: August 13, 2020
w3-total-cache.0.14.4.zip88%Ratings1,000,000+InstallsWP 3.2+Requires
Once you’ve installed and activated the plugin, you’re ready to get started.
Plugin dashboard
1. Plugin menu: You’ll see a new item Performance added to the toolbar as well as to the menu on your WordPress dashboard.
Tumblr media
Click on Performance in your dashboard sidebar and take a minute to browse through the plugin menu to get an idea of all the various feature areas.
Tumblr media
That big list can be scary, but the good thing is you may not have to deal with many items, especially on shared hosting.
2. Compatibility check, empty all caches:  The dashboard is the place to clear caching modules and check plugin-server compatibility.
Tumblr media
To begin with, click Check Compatibility. The results reveal what the plugin can or cannot do with your current server configuration. Based on the results, you can enable plugin options and see if you need additional server support for some settings.
Tumblr media
With shared hosting, you’re unlikely to be able to fix any of the compatibility issues. That’s fine – don’t stress!
Let’s get configuring now…
W3 Total cache settings – General Settings
This section of W3 Total Cache Settings is where you get to enable/disable the plugin’s individual functions. Thereafter, you can refine each function under the respective menu item.
Here’s a quick overview:
Tumblr media
Clicking the links will take you directly to that section of General Settings on the same page.
We’ll focus on the W3 Total Cache settings relevant to a shared server setup:
Some settings such as Opcode cache and Fragment cache are applicable only to premium plans. And some others like Reverse Proxy are more relevant to a private server environment or may require additional software (Monitoring).
1. General
Preview mode helps you try out changes before going live with them. You can view the changes in a separate browser and they won’t take effect until you deploy them.
Tumblr media
It’s a good idea to always use Preview mode first, as functions like minifying can break your site sometimes.
2. Page cache
This section is really the heart of the plugin. Fortunately, it’s easy to set up – just check the Enable box and select Disk: Enhanced for the method.
Tumblr media
3. Minify
Minification can sometimes break your site, so you should employ some caution here:
Tumblr media
Minification compresses and combines the many CSS and JavaScript files on your website. Selecting Auto takes care of it automatically. Make sure to preview after choosing this setting to make sure minification isn’t causing any issues on your site.
Tumblr media
4. Database cache
This one caches the results of common database queries. It can hog server resources and, on a shared server, may actually work against you. It’s best to skip this option.
Tumblr media
5. Object Cache
Object cache too can draw heavily on server resources so it’s better to keep it disabled on most shared hosting plans.
Tumblr media
6. Browser cache
This tells visitors’ browsers to save a copy of the page and reduces calls to your website. You should definitely Enable this option.
Tumblr media
7. Content delivery network
If you’re using a content delivery network (CDN), enable this one. Consult your CDN’s support for how to actually input the information, as the process depends on the exact CDN.
Tumblr media
8. Miscellaneous
Covers a bunch of settings, the first one enables a Google Page Speed dashboard widget and requires an API key. Enabling it is optional, as you can always test pages manually.
Tumblr media
Leave all other settings as the defaults.
9. Debug
Enabling this option adds debugging information at the end of each page. Unless you’re actively using it, keep it disabled. Only the modules that you enable in General Settings are available in this section.
Tumblr media
10. Import export
To replicate W3 Total Cache settings on another website, click Download to create a file containing the current active settings. Then upload this file to another site to recreate the same configuration. It can also double as a backup for W3 Total Cache settings.
Tumblr media
If you want to start afresh, click the Restore Default Settings button.
W3 Total cache settings – fine-tuning the General Settings
After enabling the different options under the General Settings Tab, you can fine-tune the enabled options by clicking the respective item in the plugin menu.
1. Page cache
General: Configure it according to the screenshot below:
Tumblr media
Enable SSL cache only if you’ve implemented SSL on your site.
Aliases: This is not useful to most websites, so skip this one.
Tumblr media
Cache preload: enabling it builds a cache automatically even before a visitor requests the page. You’ll need to type in the XML sitemap file of your website. Preload the post cache upon publish events ensures that the cached version is updated each time you publish.
Tumblr media
Purge policy: This section specifies which pages are to be purged (AKA, have the cache cleared) when a new post is published or edited.
Tumblr media
Advanced: Further, you can exclude some browsers from receiving cached versions, create exceptions and more. Enable the Compatibility mode, and leave the rest as the defaults.
Tumblr media
2. Minify
Since we have enabled the auto option for Minify under General settings, there’s not much to do here.
General: The plugin author recommends that you go with the default settings, though you could enable notification for Minify errors.
Tumblr media
HTML & XML: Enable all checkboxes, except Don’t minify feeds.
Tumblr media
JS And CSS:
Tumblr media
Advanced: Here, you can choose to exclude pages and files from minification, set the update interval and when to delete expired cache data (garbage collection). Default settings are fine, but you can change values if you wish.
Tumblr media
3. Browser cache
General: Make sure to enable Set Last-Modified Header.
Tumblr media
Also, enable gzip compression to compress text files, as well as Prevent caching of objects after settings change so browsers can identify newly cached files.
Tumblr media
Leave the rest as the defaults.
You’ll find similar options in the CSS and JS section, the HTML & XML sections and the Media section, and you can leave them as the defaults.
W3 Total Cache settings – other settings
These settings allow you to handle certain types of users differently. You don’t have to do this – but it does give you extra flexibility.
1. User agent groups
You can create a group, say for mobile users, check Enable and select the relevant theme. While creating multiple groups, place the most important group at the top.
Tumblr media
To direct a group (say, Android users) to an entirely different site, paste the URL of that website in the Redirect Users To field.
2. Manage referrer groups
This setting directs users coming from different sources such as Google or Bing, to cached webpages specific to that set of users.
Tumblr media
3. Cookie groups
Use this setting to create different sets of cookies and assign it to specific groups like subscribers or mobile users to create a unique cache for each.
Tumblr media
Enjoy your faster WordPress site
That covers most of the basic settings for W3 Total Cache. After configuring your site like this, you should be set up to enjoy significantly faster page load times.
The post How to use W3 Total Cache Settings Explained – A Beginner’s Guide appeared first on The Coding Bus.
from WordPress https://ift.tt/3h3Bf1f via IFTTT
0 notes
solaceinfotechpvtltd · 5 years ago
Text
Drupal 8 Is Not A CMS, It’s CMF
Tumblr media
https://solaceinfotech.com/blog/drupal-8-is-not-a-cms-its-cmf/
Drupal is a scalable, open platform for web content and digital experiences management. It is a free platform written in PHP and distributed under the General Public License. It provides profound capabilities and endless flexibility on the web. Initially, we were also installing and configuring Drupal, creating content types, menus, views, taxonomy etc. to create not just beautiful but secured and performing websites.
When JS framework and decoupling came to the market, we coordinated AngularJS with Drupal to create more user-friendly websites. This blog is about – Drupal is CMS  or CMF? To know this, first of all see What is CMS and What is CMF?
CMS-
A content management system (CMS) is a computer program which allows publishing, editing and modifying content on a web site as well as maintenance from a central page. A content management system, should be ready to go right out of the limit- something that non-developer can easily setup to use. The main purpose of the CMS is to manage the content( For eg., WordPress).
CMF-
A content management framework (CMF) is a system that facilitates the use of reusable components or customized software for managing web content. A CMF is more like a box of Legos. It could be used to make something very simple, or in the hands of an expert, it could be used to make something VERY complicated.
One of the popular views of a CMF is that, it has to be based on MVC(Model, Views, Controller) architecture. For eg., CodeIgniter, CakePHP.
CMS vs CMF-
In about 2001 Dries Buytaert released Drupal. It began similarly as a simple forum software. However, thanks to the invention of the Node, it quickly evolved from there.
Until Version 4.6, Drupal was still a Node management system or a CMS.
But then something changed…
In Version 4.7, Drupal now had the ability of two awesome Modules called CCK and Views. This was the real turning point for Drupal. This was a point, when it stopped being a CMS and starting to become a true Framework.
This is when all these pre-defined Nodes started being replaced with “text-fields” and “date-fields” and “image-fields“. No longer were we confined to using a pre-built solution, we were instead encouraged to build our own. From few years with Drupal 8, you can see that transformation is almost complete.
Never again will you discover Recipe Modules for download. The expectation for Drupal these days is that you will build your own content.
Compatible modules or functionality to call it a CMF-
1. Exchange of relevant data-
It is helpful to reuse the data on numerous applications, after feeding it once on a single application. Whereas the creation of content is a tedious, time-consuming and costly task. Based on the requirement, whole or sub-set of data can be exchanged within numerous applications. One of the most important benefits of Drupal for exchanging the data is Feeds. These feeds are used to import data, while Views with JSON or XML format output helps to export or provide the required data to third-party applications. Out of the box modules that integrate with various Geolocation tools, Payment Services, Social Networks, CRM, ERP and many other open standards are also available in Drupal.
2. Third party authentication-
For any application, the users’ journey begins with sign-up and login so that users can access the authorized content.
Nowadays, where everything is available just on click, sign-up and login should be quick and easy. So, now almost each application provides a social media login or SSO so that their users can access the authorized content or sub-domain or sub-sites. This authentication process must be secure while being quick. Various authentication modules are available on Drupal like Google authentication, Social Media sign-ins etc. Apart from this, customization can also be done using Authentication API, RESTful web services API for 3rd party application sign-ins.
3. Subscription or user type based Access control-
Content authoring and publishing requires a workflow and necessary permission to access the draft or review content. An access control of data also vary based on subscription for the end user or any third-party consumer. Roles and permissions gives access control which is more than enough, however, the Workflow and Rules module can be configured for particular access requirements. Higher customization can be done if required as RESTful web services API are part of Drupal core.
4. Having large numbers of users-
If the time required to produce and give the result to the end-user is minimum, then the framework will engage more users. Also caching the result or data is the best part to solve this purpose.
Drupal provides multiple caching for blocks, pages etc. and also it is quite intelligent. Drupal has a benefit of setting the cache timer which require special access permission to the end user. For eg., About us page or most popular articles block can be cached from a few hours to days. Whereas, latest Tweets or Facebook posts to be cached only for 15 Mins to a few hours only. This can be increased using Memcache, Varnish, APC or PHP 7 opcode cache.
5. Integration with JS Framework like Angular, React-
Drupal provides flexibility to apply animation to represent data, also have desired look and feel for the same block or change and update it whenever required.
JS framework can be integrated by using libraries and tweaking the template file. However, to make it easier now Drupal is looking to adopt React.This implies the application can use the best of both worlds. Where Drupal will provide the user, content management, and workflow. Also, by using feed, REST APIs or views (as mentioned above) the representation of data can be beautify using JS frameworks.
6. Quick turnaround for production setup-
Out of the limitations, distributions are available on Drupal to develop basic commerce or social media sites. Due to this, developing a basic commerce site would only take a few days.
Configuration Management System, Distribution (installation profiles) help for a quick turnaround along with the features, hook_install, and devel module to create dummy data (If required). As a result, this helps in creating multiple instances of the same site.
7. E2E and automated testing-
Automation also helps in test coverage, data-driven testing, and performing different types of testing such as Functional, Regression, Smoke, API, etc. – both, efficiently and effectively.
This is possible because of simpletest, an integral part of Drupal that requires the developer to write test files at the time of module writing so that any changes in the modules can be verified then and there; and is largely used for Behavior Driven Development. Thereby, saving a lot of time and cost.
Conclusion-
Considering these benefits Drupal provides, it is more than a CMS, it is a CMF.
0 notes
qwertsypage · 6 years ago
Text
Case Study: Nameserver Issue Investigation using curl, dig+trace & nslookup
Tumblr media
In the following blogpost, we will walk you through how we chased down a DNS resolution issue for one of our clients. Even though the problem at hand was very specific, you might find the steps we took during the investigation useful. Also, the tools we used might also prove to be helpful in case you'd face something similar in the future. We will also discuss how the Domain Name System (works), so buckle up!
The Symptoms
Our client hosts their static assets and webshop at a hosting provider. They also provide a Wordpress like CMS and nameservers as well. The client wanted to reduce costs, so they asked us to move their static assets to AWS S3 and setup CloudFront to cache them. The client set up a CNAME record pointing to the CloudFront, thus it was available at assets.clients-domain.com as well as distribution-id.cloudfront.net
Setting up CloudFront was pretty straightforward. However, we were pretty surprised when we got a ticket claiming that images are not visible when the site is visited from a mobile browser. Another subcontractor, who handles the development of the static pages reported that they can only access them from certain locations, but from others, they are not available.
Forming the DNS resolution error hypothesis, or why 'curl' is better than browsers
The first method we tried to reproduce the error was accessing the resource from the browser at https://assets.clients-domain.com/img/test-image.png. It was pretty difficult as browsers had no problem loading the assets in our office. Then we used a VPN to test them from other locations.
The results were inconsistent: with disabling the browser cache the images we tested were loaded from one location without issues, from others it failed at first with 502 Bad Gateway. Then, at some point, it started working and we weren't able to break it again no matter how hard we tried. Then we tried using curl. 50% of the time it worked, but the other 50% it reported:
$ curl https://assets.clients-domain.com/img/test-image.png --output test.png % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0curl: (6) Could not resolve host: assets.clients-domain.com
Once we saw Could not resolve host: assets.clients-domain.com it was clear that we are facing a DNS issue. Or at least it was an educated guess worth verifying.
'dig'-ing deep for verification
To verify our hypothesis, we tried to reach CloudFront straight. It worked fine, so we knew we were on the right track..
First, we thought there might be a problem with the way we set up the CNAME record in CloudFront, so we started digging. We opened two panels in our terminals next to each other and ran watch curl https://assets.clients-domain.com/img/test-image.png --output test.png and watch dig assets.clients-domain.com.
dig reported the following when curl failed to reach the server:
$ watch dig assets.clients-domain.com ; <<>> DiG 9.13.5 <<>> assets.clients-domain.com ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 24152 ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags:; udp: 4096 ;; QUESTION SECTION: ;assets.clients-ip.com. IN A ;; AUTHORITY SECTION: clients-ip.com. 300 IN SOA virga.hosting-service.com. root.virga.hosting-service.com. 2018091202 10800 3600 604800 86400 ;; Query time: 183 msec ;; SERVER: 213.46.246.53#53(213.46.246.53) ;; WHEN: Fri Feb 01 17:18:12 CET 2019 ;; MSG SIZE rcvd: 106
When we got a proper answer section, curl managed to download the asset.
$ watch dig assets.clients-domain.com ; <<>> DiG 9.13.5 <<>> assets.clients-domain.com ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 51530 ;; flags: qr rd ra; QUERY: 1, ANSWER: 5, AUTHORITY: 0, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags:; udp: 4096 ;; QUESTION SECTION: ;assets.clients-domain.com. IN A ;; ANSWER SECTION: assets.clients-domain.com. 297 IN CNAME distribution-id.cloudfront.net. distribution-id.cloudfront.net. 57 IN A 13.32.22.20 distribution-id.cloudfront.net. 57 IN A 13.32.22.108 distribution-id.cloudfront.net. 57 IN A 13.32.22.112 distribution-id.cloudfront.net. 57 IN A 13.32.22.152 ;; Query time: 22 msec ;; SERVER: 213.46.246.53#53(213.46.246.53) ;; WHEN: Fri Feb 01 17:17:51 CET 2019 ;; MSG SIZE rcvd: 156
Now we started to suspect the problem is not on our side after all. However, let's dissect the output of dig first.
Dig is a DNS lookup utility program that you can use to gain information on how a domain name is mapped to an IP address. You can pass it several options, such as +cmd which prints dig's version and the command you entered to the terminal. To omit it, you can use dig +nocmd assets.clients-domain.com.
Tumblr media
There are several other options such as +short which will give you a terser, parseable output, or +trace which will trace the nameservers that were used for the domain name resolution. After the issued command you can also see the ->>HEADER<<- printed. We either got NXDOMAIN stating that the domain we are looking for is non-existent, or NOERROR, when we get back the IP address for the query.
The QUESTION SECTION reminds us of the domain and subdomains we were looking for and of the fact that we were looking for an A record, thus essentially for an IP address.
When the DNS resolution fails, we are only given an AUTHORITY SECTION which tells us that dig was able to find the domain authority (SOA), but was not able to find anything that points to the subdomain.
However, when dig is able to resolve the subdomain, it tells us that it found a CNAME record on the authoritative nameserver pointing to CloudFront, and provides us with the IP addresses of CloudFront’s nameservers, as you can see highlighted below.
;; ANSWER SECTION: assets.clients-domain.com. 297 IN CNAME distribution-id.cloudfront.net. distribution-id.cloudfront.net. 57 IN A 13.32.22.20 distribution-id.cloudfront.net. 57 IN A 13.32.22.108 distribution-id.cloudfront.net. 57 IN A 13.32.22.112 distribution-id.cloudfront.net. 57 IN A 13.32.22.152
Now that we understand the output of dig, let's continue with the investigation.
'+trace'-ing nameservers
We wanted to see where the domain name resolution got stuck when we encountered failures, so we ran dig +trace assets.clients-domain.com. Again, we had two different kinds of output. One where the resolution failed:
$ dig +trace assets.clients-domain.com ; <<>> DiG 9.13.5 <<>> +trace assets.clients-domain.com ;; global options: +cmd . 84782 IN NS h.root-servers.net. . 84782 IN NS a.root-servers.net. . 84782 IN NS e.root-servers.net. . 84782 IN NS l.root-servers.net. . 84782 IN NS f.root-servers.net. . 84782 IN NS c.root-servers.net. . 84782 IN NS g.root-servers.net. . 84782 IN NS b.root-servers.net. . 84782 IN NS k.root-servers.net. . 84782 IN NS j.root-servers.net. . 84782 IN NS d.root-servers.net. . 84782 IN NS m.root-servers.net. . 84782 IN NS i.root-servers.net. . 84782 IN RRSIG NS 8 0 518400 20190214050000 20190201040000 16749 . K8k6KqovcMQnSsYoh+9rLiBK2423be5fvZb06NdcRz1tGqsigMQEZg2k IzOv9iPmqqcS0eB5mVxdm1NXcoRYuGQcSwTA9yBWcgs1AZxiEMOIJLNT JTxyiClPo2KKFe32pfJN1ljzZhSP26KI+/htBbRsX0qZARs80cfXOo5v ZUMO875h4ldHI9+UbR9PpkFtfmSHINkiatMQRczFScV0e0Zelqwd9QUq mBzU3vnhw+gqtxyTowkQ4hGictt/KVdJDPqkrV0BFqWocmaoryORGDnv 2IRLyV1uNB0jJrXnzwP492L4d1OhSRslGNfJPotsfNY7cMb2Z6xfO9RL Hvylgg== ;; Received 540 bytes from 213.46.246.53#53(213.46.246.53) in 14 ms com. 172800 IN NS f.gtld-servers.net. com. 172800 IN NS b.gtld-servers.net. com. 172800 IN NS h.gtld-servers.net. com. 172800 IN NS g.gtld-servers.net. com. 172800 IN NS k.gtld-servers.net. com. 172800 IN NS c.gtld-servers.net. com. 172800 IN NS a.gtld-servers.net. com. 172800 IN NS m.gtld-servers.net. com. 172800 IN NS j.gtld-servers.net. com. 172800 IN NS e.gtld-servers.net. com. 172800 IN NS d.gtld-servers.net. com. 172800 IN NS l.gtld-servers.net. com. 172800 IN NS i.gtld-servers.net. com. 86400 IN DS 30909 8 2 E2D3C916F6DEEAC73294E8268FB5885044A833FC5459588F4A9184CF C41A5766 com. 86400 IN RRSIG DS 8 1 86400 20190214050000 20190201040000 16749 . OTMp18F8zF6IFwUeH4PC4owXLtMIxejaBs+r2PkgIxM5dDtGIj+JXF6R kXmxsQi7FlMhQq/OxU7B3HksQ8CCXVb4rYEo+6vz8ugElRkGKBZf0tkd 4C/JjleSX5kAHdgYnK5m/0bWq4wxMw+R0sSdsbnVmc+Jzv/S3T+Aj4la 0heACCqQYY+2rrGBJ7pxTWjR2JvK8p8NgVvx6k3fZlG0p5QbnajnGMMY vyB/GtYv3uvLnS4JLQvUMU7meIq6hm+wqpI1kp676ypu+KvoqQVFaO/E u4Rbv7ie5CsQOT4H/7jc8pw6IQqqD3FjdFX2yoW4u9pSwy8LrDgYHix7 AielIA== ;; Received 1208 bytes from 192.112.36.4#53(g.root-servers.net) in 55 ms clients-domain.com. 172800 IN NS ns2.hosting-nameserver.com. clients-domain.com. 172800 IN NS ns1.hosting-nameserver.com. CK0POJMG874LJREF7EFN8430QVIT8BSM.com. 86400 IN NSEC3 1 1 0 - CK0Q1GIN43N1ARRC9OSM6QPQR81H5M9A NS SOA RRSIG DNSKEY NSEC3PARAM CK0POJMG874LJREF7EFN8430QVIT8BSM.com. 86400 IN RRSIG NSEC3 8 2 86400 20190208054243 20190201043243 16883 com. LzTH+svBHgjuQk3FHAvNO72auLxibi3E6gzqFOkT7BwVqEYSLLd6b2fn r+y8A5fYEsR7VDRS6F+fODsOXlvfAR/Dr4oww/8FYMlAG7eYr5g4Bcsv TTnAqdXhPDoJgfZ6+BTodLgbY6tYZWNNnV2wS/iv0xfZ3BpAVnXEqgmD GrE= FJ6U8VTBKL1C7L340CMMNNFNL3DP254G.com. 86400 IN NSEC3 1 1 0 - FJ70PP8IH3U3OPHIR4INIE39O39HKIVK NS DS RRSIG FJ6U8VTBKL1C7L340CMMNNFNL3DP254G.com. 86400 IN RRSIG NSEC3 8 2 86400 20190207061242 20190131050242 16883 com. P5v6fKCuxOuzfmR2IXXZgns/m+NkvDJ2Ph4Az/Rbs+VkOV8jTHlPr/FZ k7EvoW06jHUbDLqa0UdY92IFcK/Z0kEO3t76mcQtd/0WXvVQkBHCyb0Q UfaxxPe00oeEh8Ic/6u5Zz/Co0i7rYXoVKQIprTqngs+x3g5luUogp/Y iLE= ;; Received 612 bytes from 192.48.79.30#53(j.gtld-servers.net) in 278 ms clients-domain.com. 300 IN SOA virga.hosting-nameserver.com. root.virga.anticsdms.com. 2018091202 10800 3600 604800 86400 ;; Received 106 bytes from 50.56.75.143#53(ns2.hosting-nameserver.com) in 217 ms
And another when the domain name got resolved properly:
⇣96% ➜ dig +trace assets.clients-domain.com ; <<>> DiG 9.13.5 <<>> +trace assets.clients-domain.com ;; global options: +cmd . 79456 IN NS e.root-servers.net. . 79456 IN NS b.root-servers.net. . 79456 IN NS d.root-servers.net. . 79456 IN NS j.root-servers.net. . 79456 IN NS m.root-servers.net. . 79456 IN NS i.root-servers.net. . 79456 IN NS l.root-servers.net. . 79456 IN NS g.root-servers.net. . 79456 IN NS c.root-servers.net. . 79456 IN NS k.root-servers.net. . 79456 IN NS f.root-servers.net. . 79456 IN NS a.root-servers.net. . 79456 IN NS h.root-servers.net. . 79456 IN RRSIG NS 8 0 518400 20190214050000 20190201040000 16749 . K8k6KqovcMQnSsYoh+9rLiBK2423be5fvZb06NdcRz1tGqsigMQEZg2k IzOv9iPmqqcS0eB5mVxdm1NXcoRYuGQcSwTA9yBWcgs1AZxiEMOIJLNT JTxyiClPo2KKFe32pfJN1ljzZhSP26KI+/htBbRsX0qZARs80cfXOo5v ZUMO875h4ldHI9+UbR9PpkFtfmSHINkiatMQRczFScV0e0Zelqwd9QUq mBzU3vnhw+gqtxyTowkQ4hGictt/KVdJDPqkrV0BFqWocmaoryORGDnv 2IRLyV1uNB0jJrXnzwP492L4d1OhSRslGNfJPotsfNY7cMb2Z6xfO9RL Hvylgg== ;; Received 540 bytes from 213.46.246.53#53(213.46.246.53) in 18 ms com. 172800 IN NS k.gtld-servers.net. com. 172800 IN NS h.gtld-servers.net. com. 172800 IN NS g.gtld-servers.net. com. 172800 IN NS a.gtld-servers.net. com. 172800 IN NS d.gtld-servers.net. com. 172800 IN NS m.gtld-servers.net. com. 172800 IN NS i.gtld-servers.net. com. 172800 IN NS l.gtld-servers.net. com. 172800 IN NS e.gtld-servers.net. com. 172800 IN NS j.gtld-servers.net. com. 172800 IN NS f.gtld-servers.net. com. 172800 IN NS c.gtld-servers.net. com. 172800 IN NS b.gtld-servers.net. com. 86400 IN DS 30909 8 2 E2D3C916F6DEEAC73294E8268FB5885044A833FC5459588F4A9184CF C41A5766 com. 86400 IN RRSIG DS 8 1 86400 20190214050000 20190201040000 16749 . OTMp18F8zF6IFwUeH4PC4owXLtMIxejaBs+r2PkgIxM5dDtGIj+JXF6R kXmxsQi7FlMhQq/OxU7B3HksQ8CCXVb4rYEo+6vz8ugElRkGKBZf0tkd 4C/JjleSX5kAHdgYnK5m/0bWq4wxMw+R0sSdsbnVmc+Jzv/S3T+Aj4la 0heACCqQYY+2rrGBJ7pxTWjR2JvK8p8NgVvx6k3fZlG0p5QbnajnGMMY vyB/GtYv3uvLnS4JLQvUMU7meIq6hm+wqpI1kp676ypu+KvoqQVFaO/E u4Rbv7ie5CsQOT4H/7jc8pw6IQqqD3FjdFX2yoW4u9pSwy8LrDgYHix7 AielIA== ;; Received 1208 bytes from 199.9.14.201#53(b.root-servers.net) in 188 ms clients-domain.com. 172800 IN NS ns2.hosting-nameserver.com. clients-domain.com. 172800 IN NS ns1.hosting-nameserver.com. CK0POJMG874LJREF7EFN8430QVIT8BSM.com. 86400 IN NSEC3 1 1 0 - CK0Q1GIN43N1ARRC9OSM6QPQR81H5M9A NS SOA RRSIG DNSKEY NSEC3PARAM CK0POJMG874LJREF7EFN8430QVIT8BSM.com. 86400 IN RRSIG NSEC3 8 2 86400 20190208054243 20190201043243 16883 com. LzTH+svBHgjuQk3FHAvNO72auLxibi3E6gzqFOkT7BwVqEYSLLd6b2fn r+y8A5fYEsR7VDRS6F+fODsOXlvfAR/Dr4oww/8FYMlAG7eYr5g4Bcsv TTnAqdXhPDoJgfZ6+BTodLgbY6tYZWNNnV2wS/iv0xfZ3BpAVnXEqgmD GrE= FJ6U8VTBKL1C7L340CMMNNFNL3DP254G.com. 86400 IN NSEC3 1 1 0 - FJ70PP8IH3U3OPHIR4INIE39O39HKIVK NS DS RRSIG FJ6U8VTBKL1C7L340CMMNNFNL3DP254G.com. 86400 IN RRSIG NSEC3 8 2 86400 20190207061242 20190131050242 16883 com. P5v6fKCuxOuzfmR2IXXZgns/m+NkvDJ2Ph4Az/Rbs+VkOV8jTHlPr/FZ k7EvoW06jHUbDLqa0UdY92IFcK/Z0kEO3t76mcQtd/0WXvVQkBHCyb0Q UfaxxPe00oeEh8Ic/6u5Zz/Co0i7rYXoVKQIprTqngs+x3g5luUogp/Y iLE= ;; Received 612 bytes from 192.12.94.30#53(e.gtld-servers.net) in 29 ms assets.clients-domain.com. 300 IN CNAME distribution-id.cloudfront.net. ;; Received 92 bytes from 162.242.147.111#53(ns1.hosting-nameserver.com) in 268 ms
The majority of both answers are the same. To understand them first let's take a look at how the DNS system works.
Domain Name System (DNS) in short
There are two types of nameservers: non-authoritative or resolver cache servers and authoritative servers.
First, clients will send a request to the default nameserver, which is either provided by your ISP, or anything you set up in your router's settings. If you ever fiddled with it, you probably changed it to 8.8.8.8 or 8.8.4.4 which are Google's resolver cache servers. These will return the cached address for the requested domain if it's still valid or refer the request up the chain. This chain is what we traced with dig.
First, we are directed to the root servers. They are at the top of the DNS hierarchy and are the ones that will refer requests to the appropriate TLD servers. In our case, we have a .com domain, so we are redirected to the nameservers that manage .com TLDs. It could have an authoritative answer to the query or will have an NS record, referring to another nameserver down the chain. You can check the authoritative nameservers of any TLD, domain name or even subdomain by using dig -t ns.
$ dig -t ns com ; <<>> DiG 9.13.5 <<>> -t ns com ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 9967 ;; flags: qr rd ra; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags:; udp: 4096 ;; QUESTION SECTION: ;com. IN NS ;; ANSWER SECTION: com. 86400 IN NS d.gtld-servers.net. com. 86400 IN NS g.gtld-servers.net. com. 86400 IN NS l.gtld-servers.net. com. 86400 IN NS m.gtld-servers.net. com. 86400 IN NS f.gtld-servers.net. com. 86400 IN NS k.gtld-servers.net. com. 86400 IN NS b.gtld-servers.net. com. 86400 IN NS h.gtld-servers.net. com. 86400 IN NS a.gtld-servers.net. com. 86400 IN NS i.gtld-servers.net. com. 86400 IN NS e.gtld-servers.net. com. 86400 IN NS j.gtld-servers.net. com. 86400 IN NS c.gtld-servers.net. ;; Query time: 36 msec ;; SERVER: 213.46.246.53#53(213.46.246.53) ;; WHEN: Mon Feb 04 14:10:51 CET 2019 ;; MSG SIZE rcvd: 256
As you can see, these are the same as the ones we got in the second section with +trace. These namservers contain NS records pointing to the appropriate domains may it be google.com or our clients-domain.com in question.
In both cases, we are referred to
clients-domain.com. 172800 IN NS ns2.hosting-nameserver.com. clients-domain.com. 172800 IN NS ns1.hosting-nameserver.com.
These are the authoritative nameservers of the client's domain. During our investigation, we either got stuck here, or we were further referred to CloudFront.
The fact that we got two different nameservers was not surprising as usually there are at least two of them for high-availability and load balancing. But now we started to understand where the problem is coming from. You see, browser have their own DNS cache, to make requests to frequently used domains faster, but curl does not, and having one would, of course, ruin the purpose in case of dig. Thus we guessed that browsers cached the server for the requested domain and that's why we got reliable responses after the first time it worked, but we got 50-50 error rate with from the terminal.
So we thought that maybe the CNAME record is only present on one of the authoritative nameservers of the client's hosting service provider. To test that we used nslookup specifying the nameserver we wanted to use.
Coup de grace with 'nslookup'
With nslookup you can query nameservers. To figure out what's happening we specified the domain name to be resolved with the nameservers of the hosting service, one by one.
$ nslookup assets.clients-domain.com ns1.hosting-nameserver.com Server: ns1.hosting-nameserver.com Address: 162.242.147.111#53 assets.clients-domain.com canonical name = distribution-id.cloudfront.net. ** server can't find distribution-id.cloudfront.net: REFUSED
Specifying ns1.hosting-nameserver.com we got back the CNAME (canonical name) record pointing to CloudFront. Of course, it refused the resolution of distribution-id.cluodfornt.net as it is not an authoritative nameserver of CloudFront, but at least we saw that this nameserver has the proper record.
$ nslookup assets.clients-domain.com ns2.hosting-nameserver.com Server: ns2.hosting-nameserver.com Address: 50.56.75.143#53 ** server can't find assets.clients-domain.com: NXDOMAIN
Then when we queried ns2.hosting-nameserver.com we got NXDOMAIN just as when the domain name resolution broke with dig or when we weren't able to load the images from the browsers. Finally, these results were consistent across different locations no matter how many times we ran nslookup.
Thus, we were able to conclude that the problem stemmed from the fact that one of the nameservers was missing the CNAME record pointing to CloudFront. We let the client know to handle this with their hosting service, and a day later the issue got resolved.
Conclusion
In this blogpost we described how we saw symptoms of assets loading inconsistently from AWS S3 with CloudFront, how we used curl to get a more simple answer than what was provided by the browsers. We went on to investigate the issue with dig +trace only to find out that the DNS resolution was stuck at the authoritative nameserver of the domain. Then we finally put an end to the investigation by using nslookup querying the two authoritative nameservers one by one.
Case Study: Nameserver Issue Investigation using curl, dig+trace & nslookup published first on https://koresolpage.tumblr.com/
0 notes
iyarpage · 6 years ago
Text
Case Study: Nameserver Issue Investigation using curl, dig+trace & nslookup
Tumblr media
In the following blogpost, we will walk you through how we chased down a DNS resolution issue for one of our clients. Even though the problem at hand was very specific, you might find the steps we took during the investigation useful. Also, the tools we used might also prove to be helpful in case you'd face something similar in the future. We will also discuss how the Domain Name System (works), so buckle up!
The Symptoms
Our client hosts their static assets and webshop at a hosting provider. They also provide a Wordpress like CMS and nameservers as well. The client wanted to reduce costs, so they asked us to move their static assets to AWS S3 and setup CloudFront to cache them. The client set up a CNAME record pointing to the CloudFront, thus it was available at assets.clients-domain.com as well as distribution-id.cloudfront.net
Setting up CloudFront was pretty straightforward. However, we were pretty surprised when we got a ticket claiming that images are not visible when the site is visited from a mobile browser. Another subcontractor, who handles the development of the static pages reported that they can only access them from certain locations, but from others, they are not available.
Forming the DNS resolution error hypothesis, or why 'curl' is better than browsers
The first method we tried to reproduce the error was accessing the resource from the browser at https://assets.clients-domain.com/img/test-image.png. It was pretty difficult as browsers had no problem loading the assets in our office. Then we used a VPN to test them from other locations.
The results were inconsistent: with disabling the browser cache the images we tested were loaded from one location without issues, from others it failed at first with 502 Bad Gateway. Then, at some point, it started working and we weren't able to break it again no matter how hard we tried. Then we tried using curl. 50% of the time it worked, but the other 50% it reported:
$ curl https://assets.clients-domain.com/img/test-image.png --output test.png % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0curl: (6) Could not resolve host: assets.clients-domain.com
Once we saw Could not resolve host: assets.clients-domain.com it was clear that we are facing a DNS issue. Or at least it was an educated guess worth verifying.
'dig'-ing deep for verification
To verify our hypothesis, we tried to reach CloudFront straight. It worked fine, so we knew we were on the right track..
First, we thought there might be a problem with the way we set up the CNAME record in CloudFront, so we started digging. We opened two panels in our terminals next to each other and ran watch curl https://assets.clients-domain.com/img/test-image.png --output test.png and watch dig assets.clients-domain.com.
dig reported the following when curl failed to reach the server:
$ watch dig assets.clients-domain.com ; <<>> DiG 9.13.5 <<>> assets.clients-domain.com ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 24152 ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags:; udp: 4096 ;; QUESTION SECTION: ;assets.clients-ip.com. IN A ;; AUTHORITY SECTION: clients-ip.com. 300 IN SOA virga.hosting-service.com. root.virga.hosting-service.com. 2018091202 10800 3600 604800 86400 ;; Query time: 183 msec ;; SERVER: 213.46.246.53#53(213.46.246.53) ;; WHEN: Fri Feb 01 17:18:12 CET 2019 ;; MSG SIZE rcvd: 106
When we got a proper answer section, curl managed to download the asset.
$ watch dig assets.clients-domain.com ; <<>> DiG 9.13.5 <<>> assets.clients-domain.com ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 51530 ;; flags: qr rd ra; QUERY: 1, ANSWER: 5, AUTHORITY: 0, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags:; udp: 4096 ;; QUESTION SECTION: ;assets.clients-domain.com. IN A ;; ANSWER SECTION: assets.clients-domain.com. 297 IN CNAME distribution-id.cloudfront.net. distribution-id.cloudfront.net. 57 IN A 13.32.22.20 distribution-id.cloudfront.net. 57 IN A 13.32.22.108 distribution-id.cloudfront.net. 57 IN A 13.32.22.112 distribution-id.cloudfront.net. 57 IN A 13.32.22.152 ;; Query time: 22 msec ;; SERVER: 213.46.246.53#53(213.46.246.53) ;; WHEN: Fri Feb 01 17:17:51 CET 2019 ;; MSG SIZE rcvd: 156
Now we started to suspect the problem is not on our side after all. However, let's dissect the output of dig first.
Dig is a DNS lookup utility program that you can use to gain information on how a domain name is mapped to an IP address. You can pass it several options, such as +cmd which prints dig's version and the command you entered to the terminal. To omit it, you can use dig +nocmd assets.clients-domain.com.
Tumblr media
There are several other options such as +short which will give you a terser, parseable output, or +trace which will trace the nameservers that were used for the domain name resolution. After the issued command you can also see the ->>HEADER<<- printed. We either got NXDOMAIN stating that the domain we are looking for is non-existent, or NOERROR, when we get back the IP address for the query.
The QUESTION SECTION reminds us of the domain and subdomains we were looking for and of the fact that we were looking for an A record, thus essentially for an IP address.
When the DNS resolution fails, we are only given an AUTHORITY SECTION which tells us that dig was able to find the domain authority (SOA), but was not able to find anything that points to the subdomain.
However, when dig is able to resolve the subdomain, it tells us that it found a CNAME record on the authoritative nameserver pointing to CloudFront, and provides us with the IP addresses of CloudFront’s nameservers, as you can see highlighted below.
;; ANSWER SECTION: assets.clients-domain.com. 297 IN CNAME distribution-id.cloudfront.net. distribution-id.cloudfront.net. 57 IN A 13.32.22.20 distribution-id.cloudfront.net. 57 IN A 13.32.22.108 distribution-id.cloudfront.net. 57 IN A 13.32.22.112 distribution-id.cloudfront.net. 57 IN A 13.32.22.152
Now that we understand the output of dig, let's continue with the investigation.
'+trace'-ing nameservers
We wanted to see where the domain name resolution got stuck when we encountered failures, so we ran dig +trace assets.clients-domain.com. Again, we had two different kinds of output. One where the resolution failed:
$ dig +trace assets.clients-domain.com ; <<>> DiG 9.13.5 <<>> +trace assets.clients-domain.com ;; global options: +cmd . 84782 IN NS h.root-servers.net. . 84782 IN NS a.root-servers.net. . 84782 IN NS e.root-servers.net. . 84782 IN NS l.root-servers.net. . 84782 IN NS f.root-servers.net. . 84782 IN NS c.root-servers.net. . 84782 IN NS g.root-servers.net. . 84782 IN NS b.root-servers.net. . 84782 IN NS k.root-servers.net. . 84782 IN NS j.root-servers.net. . 84782 IN NS d.root-servers.net. . 84782 IN NS m.root-servers.net. . 84782 IN NS i.root-servers.net. . 84782 IN RRSIG NS 8 0 518400 20190214050000 20190201040000 16749 . K8k6KqovcMQnSsYoh+9rLiBK2423be5fvZb06NdcRz1tGqsigMQEZg2k IzOv9iPmqqcS0eB5mVxdm1NXcoRYuGQcSwTA9yBWcgs1AZxiEMOIJLNT JTxyiClPo2KKFe32pfJN1ljzZhSP26KI+/htBbRsX0qZARs80cfXOo5v ZUMO875h4ldHI9+UbR9PpkFtfmSHINkiatMQRczFScV0e0Zelqwd9QUq mBzU3vnhw+gqtxyTowkQ4hGictt/KVdJDPqkrV0BFqWocmaoryORGDnv 2IRLyV1uNB0jJrXnzwP492L4d1OhSRslGNfJPotsfNY7cMb2Z6xfO9RL Hvylgg== ;; Received 540 bytes from 213.46.246.53#53(213.46.246.53) in 14 ms com. 172800 IN NS f.gtld-servers.net. com. 172800 IN NS b.gtld-servers.net. com. 172800 IN NS h.gtld-servers.net. com. 172800 IN NS g.gtld-servers.net. com. 172800 IN NS k.gtld-servers.net. com. 172800 IN NS c.gtld-servers.net. com. 172800 IN NS a.gtld-servers.net. com. 172800 IN NS m.gtld-servers.net. com. 172800 IN NS j.gtld-servers.net. com. 172800 IN NS e.gtld-servers.net. com. 172800 IN NS d.gtld-servers.net. com. 172800 IN NS l.gtld-servers.net. com. 172800 IN NS i.gtld-servers.net. com. 86400 IN DS 30909 8 2 E2D3C916F6DEEAC73294E8268FB5885044A833FC5459588F4A9184CF C41A5766 com. 86400 IN RRSIG DS 8 1 86400 20190214050000 20190201040000 16749 . OTMp18F8zF6IFwUeH4PC4owXLtMIxejaBs+r2PkgIxM5dDtGIj+JXF6R kXmxsQi7FlMhQq/OxU7B3HksQ8CCXVb4rYEo+6vz8ugElRkGKBZf0tkd 4C/JjleSX5kAHdgYnK5m/0bWq4wxMw+R0sSdsbnVmc+Jzv/S3T+Aj4la 0heACCqQYY+2rrGBJ7pxTWjR2JvK8p8NgVvx6k3fZlG0p5QbnajnGMMY vyB/GtYv3uvLnS4JLQvUMU7meIq6hm+wqpI1kp676ypu+KvoqQVFaO/E u4Rbv7ie5CsQOT4H/7jc8pw6IQqqD3FjdFX2yoW4u9pSwy8LrDgYHix7 AielIA== ;; Received 1208 bytes from 192.112.36.4#53(g.root-servers.net) in 55 ms clients-domain.com. 172800 IN NS ns2.hosting-nameserver.com. clients-domain.com. 172800 IN NS ns1.hosting-nameserver.com. CK0POJMG874LJREF7EFN8430QVIT8BSM.com. 86400 IN NSEC3 1 1 0 - CK0Q1GIN43N1ARRC9OSM6QPQR81H5M9A NS SOA RRSIG DNSKEY NSEC3PARAM CK0POJMG874LJREF7EFN8430QVIT8BSM.com. 86400 IN RRSIG NSEC3 8 2 86400 20190208054243 20190201043243 16883 com. LzTH+svBHgjuQk3FHAvNO72auLxibi3E6gzqFOkT7BwVqEYSLLd6b2fn r+y8A5fYEsR7VDRS6F+fODsOXlvfAR/Dr4oww/8FYMlAG7eYr5g4Bcsv TTnAqdXhPDoJgfZ6+BTodLgbY6tYZWNNnV2wS/iv0xfZ3BpAVnXEqgmD GrE= FJ6U8VTBKL1C7L340CMMNNFNL3DP254G.com. 86400 IN NSEC3 1 1 0 - FJ70PP8IH3U3OPHIR4INIE39O39HKIVK NS DS RRSIG FJ6U8VTBKL1C7L340CMMNNFNL3DP254G.com. 86400 IN RRSIG NSEC3 8 2 86400 20190207061242 20190131050242 16883 com. P5v6fKCuxOuzfmR2IXXZgns/m+NkvDJ2Ph4Az/Rbs+VkOV8jTHlPr/FZ k7EvoW06jHUbDLqa0UdY92IFcK/Z0kEO3t76mcQtd/0WXvVQkBHCyb0Q UfaxxPe00oeEh8Ic/6u5Zz/Co0i7rYXoVKQIprTqngs+x3g5luUogp/Y iLE= ;; Received 612 bytes from 192.48.79.30#53(j.gtld-servers.net) in 278 ms clients-domain.com. 300 IN SOA virga.hosting-nameserver.com. root.virga.anticsdms.com. 2018091202 10800 3600 604800 86400 ;; Received 106 bytes from 50.56.75.143#53(ns2.hosting-nameserver.com) in 217 ms
And another when the domain name got resolved properly:
⇣96% ➜ dig +trace assets.clients-domain.com ; <<>> DiG 9.13.5 <<>> +trace assets.clients-domain.com ;; global options: +cmd . 79456 IN NS e.root-servers.net. . 79456 IN NS b.root-servers.net. . 79456 IN NS d.root-servers.net. . 79456 IN NS j.root-servers.net. . 79456 IN NS m.root-servers.net. . 79456 IN NS i.root-servers.net. . 79456 IN NS l.root-servers.net. . 79456 IN NS g.root-servers.net. . 79456 IN NS c.root-servers.net. . 79456 IN NS k.root-servers.net. . 79456 IN NS f.root-servers.net. . 79456 IN NS a.root-servers.net. . 79456 IN NS h.root-servers.net. . 79456 IN RRSIG NS 8 0 518400 20190214050000 20190201040000 16749 . K8k6KqovcMQnSsYoh+9rLiBK2423be5fvZb06NdcRz1tGqsigMQEZg2k IzOv9iPmqqcS0eB5mVxdm1NXcoRYuGQcSwTA9yBWcgs1AZxiEMOIJLNT JTxyiClPo2KKFe32pfJN1ljzZhSP26KI+/htBbRsX0qZARs80cfXOo5v ZUMO875h4ldHI9+UbR9PpkFtfmSHINkiatMQRczFScV0e0Zelqwd9QUq mBzU3vnhw+gqtxyTowkQ4hGictt/KVdJDPqkrV0BFqWocmaoryORGDnv 2IRLyV1uNB0jJrXnzwP492L4d1OhSRslGNfJPotsfNY7cMb2Z6xfO9RL Hvylgg== ;; Received 540 bytes from 213.46.246.53#53(213.46.246.53) in 18 ms com. 172800 IN NS k.gtld-servers.net. com. 172800 IN NS h.gtld-servers.net. com. 172800 IN NS g.gtld-servers.net. com. 172800 IN NS a.gtld-servers.net. com. 172800 IN NS d.gtld-servers.net. com. 172800 IN NS m.gtld-servers.net. com. 172800 IN NS i.gtld-servers.net. com. 172800 IN NS l.gtld-servers.net. com. 172800 IN NS e.gtld-servers.net. com. 172800 IN NS j.gtld-servers.net. com. 172800 IN NS f.gtld-servers.net. com. 172800 IN NS c.gtld-servers.net. com. 172800 IN NS b.gtld-servers.net. com. 86400 IN DS 30909 8 2 E2D3C916F6DEEAC73294E8268FB5885044A833FC5459588F4A9184CF C41A5766 com. 86400 IN RRSIG DS 8 1 86400 20190214050000 20190201040000 16749 . OTMp18F8zF6IFwUeH4PC4owXLtMIxejaBs+r2PkgIxM5dDtGIj+JXF6R kXmxsQi7FlMhQq/OxU7B3HksQ8CCXVb4rYEo+6vz8ugElRkGKBZf0tkd 4C/JjleSX5kAHdgYnK5m/0bWq4wxMw+R0sSdsbnVmc+Jzv/S3T+Aj4la 0heACCqQYY+2rrGBJ7pxTWjR2JvK8p8NgVvx6k3fZlG0p5QbnajnGMMY vyB/GtYv3uvLnS4JLQvUMU7meIq6hm+wqpI1kp676ypu+KvoqQVFaO/E u4Rbv7ie5CsQOT4H/7jc8pw6IQqqD3FjdFX2yoW4u9pSwy8LrDgYHix7 AielIA== ;; Received 1208 bytes from 199.9.14.201#53(b.root-servers.net) in 188 ms clients-domain.com. 172800 IN NS ns2.hosting-nameserver.com. clients-domain.com. 172800 IN NS ns1.hosting-nameserver.com. CK0POJMG874LJREF7EFN8430QVIT8BSM.com. 86400 IN NSEC3 1 1 0 - CK0Q1GIN43N1ARRC9OSM6QPQR81H5M9A NS SOA RRSIG DNSKEY NSEC3PARAM CK0POJMG874LJREF7EFN8430QVIT8BSM.com. 86400 IN RRSIG NSEC3 8 2 86400 20190208054243 20190201043243 16883 com. LzTH+svBHgjuQk3FHAvNO72auLxibi3E6gzqFOkT7BwVqEYSLLd6b2fn r+y8A5fYEsR7VDRS6F+fODsOXlvfAR/Dr4oww/8FYMlAG7eYr5g4Bcsv TTnAqdXhPDoJgfZ6+BTodLgbY6tYZWNNnV2wS/iv0xfZ3BpAVnXEqgmD GrE= FJ6U8VTBKL1C7L340CMMNNFNL3DP254G.com. 86400 IN NSEC3 1 1 0 - FJ70PP8IH3U3OPHIR4INIE39O39HKIVK NS DS RRSIG FJ6U8VTBKL1C7L340CMMNNFNL3DP254G.com. 86400 IN RRSIG NSEC3 8 2 86400 20190207061242 20190131050242 16883 com. P5v6fKCuxOuzfmR2IXXZgns/m+NkvDJ2Ph4Az/Rbs+VkOV8jTHlPr/FZ k7EvoW06jHUbDLqa0UdY92IFcK/Z0kEO3t76mcQtd/0WXvVQkBHCyb0Q UfaxxPe00oeEh8Ic/6u5Zz/Co0i7rYXoVKQIprTqngs+x3g5luUogp/Y iLE= ;; Received 612 bytes from 192.12.94.30#53(e.gtld-servers.net) in 29 ms assets.clients-domain.com. 300 IN CNAME distribution-id.cloudfront.net. ;; Received 92 bytes from 162.242.147.111#53(ns1.hosting-nameserver.com) in 268 ms
The majority of both answers are the same. To understand them first let's take a look at how the DNS system works.
Domain Name System (DNS) in short
There are two types of nameservers: non-authoritative or resolver cache servers and authoritative servers.
First, clients will send a request to the default nameserver, which is either provided by your ISP, or anything you set up in your router's settings. If you ever fiddled with it, you probably changed it to 8.8.8.8 or 8.8.4.4 which are Google's resolver cache servers. These will return the cached address for the requested domain if it's still valid or refer the request up the chain. This chain is what we traced with dig.
First, we are directed to the root servers. They are at the top of the DNS hierarchy and are the ones that will refer requests to the appropriate TLD servers. In our case, we have a .com domain, so we are redirected to the nameservers that manage .com TLDs. It could have an authoritative answer to the query or will have an NS record, referring to another nameserver down the chain. You can check the authoritative nameservers of any TLD, domain name or even subdomain by using dig -t ns.
$ dig -t ns com ; <<>> DiG 9.13.5 <<>> -t ns com ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 9967 ;; flags: qr rd ra; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags:; udp: 4096 ;; QUESTION SECTION: ;com. IN NS ;; ANSWER SECTION: com. 86400 IN NS d.gtld-servers.net. com. 86400 IN NS g.gtld-servers.net. com. 86400 IN NS l.gtld-servers.net. com. 86400 IN NS m.gtld-servers.net. com. 86400 IN NS f.gtld-servers.net. com. 86400 IN NS k.gtld-servers.net. com. 86400 IN NS b.gtld-servers.net. com. 86400 IN NS h.gtld-servers.net. com. 86400 IN NS a.gtld-servers.net. com. 86400 IN NS i.gtld-servers.net. com. 86400 IN NS e.gtld-servers.net. com. 86400 IN NS j.gtld-servers.net. com. 86400 IN NS c.gtld-servers.net. ;; Query time: 36 msec ;; SERVER: 213.46.246.53#53(213.46.246.53) ;; WHEN: Mon Feb 04 14:10:51 CET 2019 ;; MSG SIZE rcvd: 256
As you can see, these are the same as the ones we got in the second section with +trace. These namservers contain NS records pointing to the appropriate domains may it be google.com or our clients-domain.com in question.
In both cases, we are referred to
clients-domain.com. 172800 IN NS ns2.hosting-nameserver.com. clients-domain.com. 172800 IN NS ns1.hosting-nameserver.com.
These are the authoritative nameservers of the client's domain. During our investigation, we either got stuck here, or we were further referred to CloudFront.
The fact that we got two different nameservers was not surprising as usually there are at least two of them for high-availability and load balancing. But now we started to understand where the problem is coming from. You see, browser have their own DNS cache, to make requests to frequently used domains faster, but curl does not, and having one would, of course, ruin the purpose in case of dig. Thus we guessed that browsers cached the server for the requested domain and that's why we got reliable responses after the first time it worked, but we got 50-50 error rate with from the terminal.
So we thought that maybe the CNAME record is only present on one of the authoritative nameservers of the client's hosting service provider. To test that we used nslookup specifying the nameserver we wanted to use.
Coup de grace with 'nslookup'
With nslookup you can query nameservers. To figure out what's happening we specified the domain name to be resolved with the nameservers of the hosting service, one by one.
$ nslookup assets.clients-domain.com ns1.hosting-nameserver.com Server: ns1.hosting-nameserver.com Address: 162.242.147.111#53 assets.clients-domain.com canonical name = distribution-id.cloudfront.net. ** server can't find distribution-id.cloudfront.net: REFUSED
Specifying ns1.hosting-nameserver.com we got back the CNAME (canonical name) record pointing to CloudFront. Of course, it refused the resolution of distribution-id.cluodfornt.net as it is not an authoritative nameserver of CloudFront, but at least we saw that this nameserver has the proper record.
$ nslookup assets.clients-domain.com ns2.hosting-nameserver.com Server: ns2.hosting-nameserver.com Address: 50.56.75.143#53 ** server can't find assets.clients-domain.com: NXDOMAIN
Then when we queried ns2.hosting-nameserver.com we got NXDOMAIN just as when the domain name resolution broke with dig or when we weren't able to load the images from the browsers. Finally, these results were consistent across different locations no matter how many times we ran nslookup.
Thus, we were able to conclude that the problem stemmed from the fact that one of the nameservers was missing the CNAME record pointing to CloudFront. We let the client know to handle this with their hosting service, and a day later the issue got resolved.
Conclusion
In this blogpost we described how we saw symptoms of assets loading inconsistently from AWS S3 with CloudFront, how we used curl to get a more simple answer than what was provided by the browsers. We went on to investigate the issue with dig +trace only to find out that the DNS resolution was stuck at the authoritative nameserver of the domain. Then we finally put an end to the investigation by using nslookup querying the two authoritative nameservers one by one.
Case Study: Nameserver Issue Investigation using curl, dig+trace & nslookup published first on https://medium.com/@koresol
0 notes
evemilano · 5 years ago
Text
Come installare OPCACHE su Ubuntu
Come installare OPCACHE su Ubuntu
Una delle maggiori criticità riguardo i siti web è il tempo di caricamento. Uno dei modi migliori per ridurre il tempo di caricamento è abilitare sistemi di cache. Non esiste solo la cache di file HTML, OpCache infatti è una cache di opcode, che aumenta la velocità dei siti Web PHP memorizzando script precompilati bytecode nella memoria condivisa.
Mettere in cache gli script PHP significa che,…
View On WordPress
0 notes
Text
How To Install APC On Linux
How To Install APC On Linux
How to install APC on Linux ?
Ans:
The Alternative PHP Cache (APC) is a free and open opcode cache for PHP. Its goal is to provide a free, open, and robust framework for caching and optimizing PHP intermediate code. Besides being a opcode cache it provides a user cache for storing application data.
APC is a free, open, and robust framework for caching and intermediate code. Here are the most…
View On WordPress
0 notes
news47ell · 7 years ago
Text
Lightning Base Review: Managed WordPress Hosting
New Post has been published on https://www.news47ell.com/reviews/lightning-base-review-managed-wordpress-hosting/
Lightning Base Review: Managed WordPress Hosting
If you’re looking for the best managed WordPress hosting provider then you’ve come to the right place.
Since Day one, back on March 26th, 2016, the day I signed up for Lightning Base, I knew that it was going to be the place I call home for News47ell.
As I begin this Lightning Base Review, I’m going to say it now: Sign up. If you are looking for the most secure, fastest and the best managed WordPress hosting provider, look no more, because Lightning Base is all of this and much more.
Keep reading my Lightning Base review to get an in-depth look at Lightning Base and it’s exclusive features that make it one of the best managed WordPress hosting providers out there.
Lightning Base review
Coming soon.
— Lightning Base (@LightningBase) December 13, 2011
Choosing a hosting provider for your WordPress site is like choosing a house for you and your family. It needs to be:
Secure & Private: You don’t want anyone to be able to access your home.
Great environment: You want your family to live in a great neighborhood.
Built by professionals: You don’t want the house to collapse.
Upgradeable: An unplanned baby? No problem, build an extra room.
24/7 support: When something breaks inevitably, there should be a team of experts who are ready with a fix.
All managed WordPress hosting providers promise to offer the features above, but not all follow on their promises. Many fall short on the environment for example by using old architecture, some fall short on support, some on security and privacy which is really scary since you’re trusting them with your hard work. It’s unacceptable.
Lightning Base, on the other hand, follows up on everything I mentioned above. Making News47ell, more secure, with a lightning-fast loading time and a 99.9% uptime. It’s unlike anything else I have ever seen before in my life.
Why I moved to a new host
Before Lightning Base, I migrated from one host to another and finally, I settled on one that I thought was reliable. I was completely wrong.
News47ell.com started to flatline multiple times a day. I did my best trying to figure out what the hell was causing this issue but I had no luck. And, with no fix on the horizon even after I contacted their support team, I decided it was time to take News47ell somewhere else.
Yes! The red highligh on line 1 is an 8 hours and 40 minutes downtime!
I wanted to host News47ell with a top-notch managed WordPress hosting provider where I don’t even need to contact the support team in case of an emergency because there will be no case of emergencies. A host of servers that are already configured properly and maintained by professionals, where I won’t face any major issues randomly during the day that takes News47ell offline multiple times a day.
I wanted a managed WordPress hosting provider that I could watch News47ell grow old with and offer a few specific things:
PHP 7
Staging Environment
Let’s Encrypt
Options to scale
Reasonable prices
After a few days of research, I came across Lightning Base and I decided to send the support team an email to see if they offer the things I listed above.
When I got a reply from Lightning Base, I was surprised to see that the person who replied to me was Chris Piepho, the Founder of Lightning Base.
We sent emails back and forth for a week, I asked him about every tiny detail I could think of before signing up. He was very detail oriented in his replies, answering every question I had with as much information as possible. Towards the end, he assured me I would find everything I was looking for AND much more with Lightning Base.
And so, on March 26th, 2016, at 8:43 PM, I signed up for Lightning Base and with that, News47ell started a new chapter and a new journey with a new host. It actually feels more like a home now.
Make sure to read my announcement article which I published when I moved my site to Lightning Base.
The 3 Promises:
Lightning Base describes themselves as a Fast, Secure and Managed WordPress hosting provider. After hosting my site with them for nearly 2 years (1 Year, 11 Months) I can say Lightning Base kept their word and delivered.
So let’s get technical and dive in deeper in my Lightning Base review to see how Lightning Base delivers on being a fast, secure and managed WordPress hosting provider with all the features it has to offer.
Fast WordPress Hosting:
The reason why Lightning Base is a Fast WordPress hosting provider comes from the fact that Lightning Base doesn’t use NGINX, Apache, Lighttpd, Facebook HHMV or Microsoft IIS. Instead, it uses LiteSpeed.
To be more specific, LiteSpeed Enterprise, an Apache compatible, proprietary web server and a server-level caching software, developed and maintained by LiteSpeed Technologies.
LiteSpeed Web Server is the 4th most popular web server with a market share of 3.3%. It includes the following features:
HTTP/2: LiteSpeed is the first commercial server to offer full HTTP/2 support. HTTP/2 features include binary protocol, fully multiplexed and header compression.
Gzip compression: Save bandwidth by compressing the files sent to the client.
Apache Compatibility: LiteSpeed Web Server has been designed to run off Apache’s httpd.conf and .htaccess files.
Apache modules: LiteSpeed Web Server is compatible with Apache core modules like mod_rewrite, mod_security, mod_include, and mod_cache.
.Htaccess caching: LiteSpeed Web Server uses .htaccess caching to make use of .htaccess files without the performance hit.
And many, many more features…
Along with that, Lightning Base servers use 100% SSD based storage. Arranged in a Raid 10 configuration. These SSDs provide redundancy, speed and combining them with Cloudflare CDN makes for the absolute fastest access times.
Secure WordPress Hosting
According to Lightning Base:
Our servers are protected by a comprehensive, dynamic firewall, followed by a web app firewall configured to prevent malicious code.
Lightning Base isolates filesystem for each and every user and uses a set of security features that come packed with LiteSpeed. For example:
Anti-DDoS connection
Per-IP Throttling
Anti SSL BEAST
SSL Renegotiation Protection
Strict HTTP request validation
Mod_security
And much more…
If all of this isn’t enough, you can always let your traffic go through Cloudflare and use the infamous Wordfence Security WordPress plugin. And always use a complex, long password and keep it safe using 1Password.
For more info on how to keep intruders away from your site, read my tutorial: How to Protect WordPress Login Page.
Managed WordPress Hosting
Imagine this scenario: You’re busy at work and you get a phone call that a water pipe broke and water is spewing everywhere in your house. What would you do?
Call a technician to fix it?
Take time off of work, go home and try to fix it yourself? Keep in mind that you don’t know anything about fixing water pipes.
I would go with option A. Let professionals do their job.
That’s what managed WordPress hosting is all about. Letting the server administrator fix any issue the server might have, keep it fast, secure and up and running. While you focus on creating a beautiful, read-worthy content.
Throughout my time with Lightning Base, I never had to deal with any issue. It’s all managed by Chris.
Lightning Base Features
The architecture of LiteSpeed
As I mentioned above, Lightning Base isn’t your typical managed WordPress hosting provider. It uses LiteSpeed web servers. Which is capable of handling thousands of concurrent clients with minimal memory consumption and CPU usage.
Each Lightning Base site comes pre-installed with LiteSpeed cache WordPress plugin.
This plugin is loaded with dozens of features that take your WordPress site speed to the next level.
Such as:
OPcode – Object Cache (Memcached/LSMCD/Redis)
Minify CSS, JavaScript, and HTML
Combine and load CSS/JS Asynchronously
Browser Cache Support
Smart preload crawler with support for SEO-friendly sitemap
Database Cleaner and Optimizer
HTTP/2 Push for CSS/JS (on web servers that support it)
DNS Prefetch
Cloudflare API
WebP image format support
Heartbeat control
The features of this awesome plugin don’t end here. There is a set of features that are exclusive to hosts that are LiteSpeed-powered, like Lightning Base, and those features include:
Automatic page caching to greatly improve site performance
Automatic purge of related pages based on certain events
Private cache for logged-in users
Caching of WordPress REST API calls
Ability to schedule purge for specified URLs
WooCommerce and bbPress support
WordPress CLI commands
HTTP/2 & QUIC support (QUIC not available in OpenLiteSpeed)
ESI (Edge Side Includes) support.
For a full list of all exclusive and non-exclusive features, check the plugin in the WordPress directory.
As for the architecture behind Lightning Base, each and every server uses the following software:
CentOS
LiteSpeed
PHP 7.2: You can switch between PHP 5.6, 7, 7.1, and 7.2 in cPanel
MariaDB: Community developed, free fork and drop-in replacement of MySQL
Let’s Encrypt
These work together to increase the performance and speed of your site to a whole new level.
As well as making it more secure and reliable, while maintaining very similar features that everyone knows and loves. Thanks to its compatibility with Apache, its ability to read and run off Apache’s httpd.conf and .htaccess files with no configuration required.
Servers locations
When signing up, you get to choose the location of your server between 3 options: US Central – Australia Melbourne – Netherlands Amsterdam.
Chi252
Chi351
Chi352
Chi353
Chi354
Chi355
Chi356
Iwa251
Ams251
Ams252
Mel251
Both the Chicago and Amsterdam servers are powered by SingleHop, a leading global provider of hosted IT infrastructure and cloud computing that brings enterprise-class technologies to deliver a customized cloud infrastructure experience for enterprises of all sizes.
As for Melbourne, that server is powered by IBM Softlayer. Now known as IBM Cloud. A global cloud infrastructure platform built for Internet scale with a modular architecture that provides unparalleled performance, control and a global network for secure, low-latency communications.
Each one of these servers is placed strategically and optimized in a way to deliver your content anywhere around the world in a lightning fast, reliable and secure way with the absolute minimum waiting time and minimum to no downtime.
Lightning Base Dashboard
Lightning Base has a pretty clean, straightforward and easy to understand dashboard which contains everything you need to manage your account.
Active Products/Service: Easily manage your site(s) from here, access cPanel and upgrade your server and your email, or the email’s cPanel to manage spam filter and email forwarding.
Support Tickets: Have a quick access to past and current tickets and open new ones right there from your dashboard.
Domains: Transfer and Purchase domains with any .TLD .gTLD .cctld etc.
Clicking on your site in the product and service widget, it will reveal extra info about it, such as:
Disk / Bandwidth usage
Quick access to cPanel
Few cPanel shortcuts
Extra info about your site
CDN
Lightning Base takes advantage of the amazing Cloudflare CDN which makes your site load even faster anywhere around the world. As well as adding an extra layer of security and give you a set of tools that will optimize and speed up your site.
News47ell currently runs on Cloudflare. It supports both HTTP2 and Railgun, and best of all, it’s free. But if you want to pay CDN, check out KeyCDN or BunnyCDN.
Uptime
This was my main frustration with my previous host, a daily downtime of about 30 minutes with no solution in sight.
With Lightning Base, things are again very different, with an uptime of 99.9% on both Pingdom and Uptime Robot.
You can check out our public status page.
Email
With each Lightning Base account, you will get 5 email addresses, 5 GB of storage and unlimited forwarders. It’s great, free and easy to set up. You can either go with the RoundCube web client or set up apps like Mail, Spark or Thunderbird.
Free SSL
Nowadays everybody knows about Let’s Encrypt. The free, easy to deploy SSL certificate. Lightning Base offers an easy solution to deploy your SSL certificate onto your site through cPanel.
Have your own certificate? No problem! Lightning Base also offers the option to bring your own certificate and deploy it, free of charge.
Staging environment
Lightning Base does offer a staging environment. It’s a part of the cPanel software ecosystem and it works really well.
You can easily clone your production site with one click, do all the changes and development that you want. And once you’re ready, one-click is all that separates you from pushing the staging environment back to the production site.
Backups
When something is important to you, back it up, not just once, but multiple times and put the backup in multiple places. Online and offline.
That’s what Lightning Base does with their customer’s data. They perform a daily backup of all the data they have and then they copy these backups to an off-site location in case of a disaster.
Full backups are performed weekly and a database backup is performed daily. You can increase the frequency of the backups but note that it will take more of your plans bandwidth.
If you have your own storage, you can send these backups to yourself.
Customer Support
Support at Lightning Base is something out of this world. Not all managed WordPress hosting providers have a great customer support like the one provided by Lightning Base.
So why is it so good?
Most of the time when I contacted the support, it was Chris who replied to me. He’s the only one who knows exactly how his hosting environment runs.
When someone else replies, your ticket won’t travel between multiple support agents until it gets fixed. Only one is assigned to it and only that agent will reply to you. That’s good because then you wouldn’t have to re-explain your issue to every new agent that replies to a single ticket.
You will wait only a short amount of time before you get a reply from/to your tickets. It will be as detailed as you like which helps you understand exactly what caused this, how it was solved, and how to prevent it from happening again.
Isn’t that enough?
I think it is. Seeing that Chris handles most of the support tickets by himself, this helps create a great relationship between the customer and the founder. This isn’t easy to have with other managed WordPress hosting providers. This was one of the main reasons in the first place why I started writing my Lightning Base review.
Affiliate Program
This is pretty straightforward, like many affiliate programs out there. You will get a special link. Once someone visits this link, a cookie will be placed on the visitor’s computer and it will stay active for 90 days.
Once the visitor signs up, you will get 20% of the hosting plan revenue. When your account reaches $100, you can have the balance paid via Paypal.
Pricing:
Lightning Base offers a wide range of plans for everyone. Whether it’s your personal or business site. This fast and reliable Managed WordPress Hosting provider offers very generous plans to meet your demand.
Starting at $9.95/mo, this personal plan will get you 1 WordPress with 10,000 Monthly Pageviews, 1GB SSD Storage, and 10GB bandwidth.
Prices go up all the way up to $99.95/mo which allows up to 25 WordPress sites with 140,000 Monthly Pageviews, 14GB SSD Storage, and 140GB bandwidth.
All plans come with 24/7 support, backup, PHP 7 and Let’s Encrypt.
Let’s take News47ell for a spin
I did a few tests on News47ell because I wanted my Lightning Base review to contain test results taken from a live site, rather than a demo site. Because let’s face it, you want to host a real site, with millions of visitors. Not a dummy site.
After conducting multiple tests, News47ell got an impressive score on all the tests.
Bitcatcha – Test Result
Bitcatcha allows you to determine how fast your server is by testing it in 8 different locations around the world.
As you can see, News47ell got a pretty impressive score with a rating of A+
Pingdom – Test Result
Pingdom is a very popular tool that allows you to monitor the up/downtime of your website. They also provide a tool that allows you to analyze your site, check it’s load time and find any bottlenecks.
As you can see, News47ell’s performance grade is A 95 with a load time of 536 ms.
WebPageTest – Test Result
WebPageTest is another popular and much more detailed tool that tests the speed of your site using a wide range of mobile devices as well as desktop, on any browser of your choosing in locations all around the world.
As you can see, News47ell scored 1.539s on the first loading time and 0.231s on the first byte. And A grades across all other tests performed by WebPageTest
SSL Labs Powered by Qualys SSL Labs – Test Result
Last but not least there’s Qualys SSL Labs. It’s a test that determines whether your server SSL configuration is done the right way. Scott Helme describes it in a simple way in this article by saying:
‘It’s a great way to get a feel for whether or not you’re doing SSL right.’
As you can see, again, Lightning Base scores an impressive A+ rating.
Hashtag LightningBase
Here are some tweets that people sent out about their experience with Lightning Base.
Congrats to @asmallorange @KinstaHosting @LightningBase @pagely @getpantheon @pressidium @presslabs pic.twitter.com/kQ72QbVtiC
— Review Signal (@ReviewSignal) July 28, 2015
I've had a great experience migrating #WordPress sites to @LightningBase. Top notch performance and support. Wish I knew of them years ago.
— Scott Carter (@sc456a) June 30, 2016
Loving @LightningBase — awesome WP hosting. Highly recommended. Also, their support is awesome. Thanks Chris! #hosting #WordPress
— Hannah Wright (@hannahwrightAK) June 14, 2016
My new hosting company is so fast they respond to my tickets before I even finish typing them. Thanks @LightningBase
— Brittney Wilson, BSN (@TheNerdyNurse) January 10, 2015
Conclusion
Thank you for reading all the way to the end. Although we are at the end of my Lightning Base review, hopefully, this will be the start of your online journey with this amazing managed WordPress hosting provider.
The amount of love, dedication, and work that Chris put into Lightning Base is unlike anything I have ever seen. It’s truly remarkable.
Chris managed to build a state of the art managed WordPress hosting environment, unlike anything you’ve seen before. Using software that works all together in harmony to create the ultimate hosting experience for everyone using WordPress.
Don’t miss out on experiencing what it’s like to host your WordPress site with Lightning Base and maybe one day, you will write your own Lightning Base review.
Lightning Base
#LightningBase #WordPress #Hosting #LiteSpeed #WebHosting #WebPerf
0 notes
teamwpsekure · 7 years ago
Text
The Complete Guide to WordPress Caching
Nearly 80 percent of Americans now shop online. Even those who plan to shop in the store tend to research products and services on the internet before purchasing anything. For this reason, it is essential that every business owner operates a website. Nearly 75 billion business websites, personal websites and blogs use the WordPress platform, but because it is highly reliant on database queries and PHP, sites that run it may become slow. Luckily, there is a fix known as WordPress caching.
What Is Caching?
Simply put, WordPress caching is a process that makes your WordPress-based website load much faster. Each time someone visits a WordPress website, the core queries the database, which then provides the data the visitor requested. The core combines the data it retrieved and executes a PHP code that generates the HTML page. The visitor then sees the HTML page. WordPress caches the HTML websites and saves them to the server’s memory. From there, anyone who requests the page will receive the cached version. Because the site won’t need to query databases or execute PHP code, it will load much faster.
What Happens if the Page Information Changes?
Of course, websites don’t stay the same forever. Designs change, new articles get posted and readers comment. For this reason, certain activities trigger a purge of the cache. This means the previously saved page is deleted and replaced with a new version of the cache. Purging usually occurs each time the author publishes a new post or updates an old one as well as each time a reader leaves a comment.
Why Is Caching Important?
One of the most important reasons to cache your WordPress website is because of the benefits you’ll see on Google. The search engine loves fast websites and the faster yours is, the higher it will rank. Caching helps to determine the overall performance of your website and is a fundamental ranking factor regardless of how large your website is.
How Does Caching Work?
WordPress caching has two primary protocols available: client-side caching and server-side caching. When your site reuses cached data from your server, it is known as client-side caching. Most modern websites use this method because every browser supports it. Caching from the client’s side prevents the website from downloading the same data repeatedly, thereby saving time and server resources.
Server-side caching is a bit more complicated and involves four protocols: page caching, object-based caching, database query caching and opcode caching. Page caching is the simplest protocol and saves the dynamically generated HTML directly onto a server’s hard disk. Databases use a lot of resources and WordPress relies heavily on databases to operate. By saving the results of database queries and only updating when the website updates, precious resources remain available. Opcode caching is similar to database caching in that its goal is to reduce the number of database queries. However, this method saves the PHP code between requests rather than the database requests. Finally, there is object caching. This method is advanced and not used by most everyday users. It involves WordPress’ internal caching system and subsystems, which are controlled by plugins.
What Is the Most Effective Method of WordPress Caching?
Effective WordPress caching typically falls into the categories of time-based caching, action-based caching and manual caching. Time-based caching saves the website every few seconds, regardless of whether the website has been updated. However, this may negatively impact your website’s performance since most cache deletions would be unnecessary and lead to unnecessary database queries. You could alternatively set the time-based cache to occur every few minutes, hours or even once per week, but that means users would sometimes not see the most updated version of your website. Even so, caching every 24 hours is still a good option for sites that don’t use time-sensitive pages.
Most WordPress users choose to use action-based caching. This means your website would only purge and re-cache when you upload a new post, edit an old one, have a reader comment or something else on your site changes. This method is typically considered the most useful because it only queries databases when necessary and doesn’t pose the hazard of a visitor seeing an old version of the website.
Finally, you do have the option to clear your cache manually if necessary. However, this is rarely needed and typically not useful for everyday WordPress users.
How Do I Set Up Caching in WordPress?
If you are the type who prefers the do-it-yourself method, you can go into your WordPress settings and use a plugin to begin caching your site. However, if you aren’t very tech-savvy, the advanced settings can easily become confusing and you could end up doing more bad than good for your website. For this reason, most business owners decide to hire a professional company to help them optimize the speed of their website.
In addition to setting up WordPress caching, our website speed specialists offer a complete WordPress speed optimization service. Common options include the optimization of your databases, Google Fonts optimization, compacting and reducing your HTML and CSS files and tweaking the way your images load so that the initial website load is faster. If you use a shopping cart platform, these businesses can also help you improve their load times.
Should you decide to hire a WordPress specialist to help you keep your website up to speed, it is important to find one with experience and that offers a wide range of services. Check out Team WP Sekure to learn more about managing your WordPress website.
The post The Complete Guide to WordPress Caching appeared first on Team WP Sekure.
0 notes